Mega Code Archive

Categories
1) Android
2) ASP.Net
3) ASP.Net Tutorial
4) C
5) C Tutorial
6) C#
7) C# Book
8) C# by API
9) C# Tutorial
10) C++
11) C++ Tutorial
12) Delphi
13) Flash ActionScript
14) Flex
15) Java
16) Java Book
17) Java by API
18) Java Tutorial
19) JavaScript DHTML
20) JavaScript Reference
21) JavaScript Tutorial
22) MSOfficeExcel 2007 Tutorial
23) MSOfficePowerPoint 2007 Tutorial
24) MSOfficeWord 2007 Tutorial
25) MSSQL
26) MSSQL Tutorial
27) MySQL
28) MySQL Tutorial
29) Oracle PLSQL
30) Oracle PLSQL Tutorial
31) Perl
32) Php
33) PostgreSQL
34) Python
35) Python Tutorial
36) Ruby
37) Silverlight
38) VB.Net
39) VB.Net by API
40) VB.Net Tutorial
41) Visual C++ .NET
42) VisualBasic Script
43) XML
44) XML Tutorial
 
Perl
1) Array
2) CGI
3) Class
4) Data Type
5) Database
6) File
7) GUI
8) Hash
9) Language Basics
10) Network
11) Regular Expression
12) Report
13) Statement
14) String
15) Subroutine
16) System Functions
17) Win32
18) XML
Subroutine
1) A closure is an anonymous subroutine
2) A nested subroutine
3) A recursive subroutine to perform arithmetic
4) A subroutine is defined by the sub keyword and the block of code that follows
5) A subroutine that returns a scalar or a list
6) A subroutine that returns a value
7) Accessing variables in subroutines
8) Adding two arrays in a subroutine
9) Ading two arrays together
10) Anonymous functions
11) Anonymous Subroutines
12) BEGIN and END Subroutines (Startup and Finish)
13) Calculate 1000th element of standard Fibonacci sequence
14) Call a subroutine and use it
15) Call a subroutine through its reference
16) Call a subroutine without defining it
17) Call sub
18) Call subroutine with parameter by using its reference
19) Call the subroutine with $number
20) Calling a sub routine with
21) Calling a sub routine with subroutine_name()
22) Calling function in print statement
23) Calling subroutines that are not defined before use
24) Check the prototype
25) Closure in action
26) Context and Subroutines
27) Create a subroutine
28) Declaration with prototype
29) Define local variable in subroutine by using my
30) Define subroutine and call it with using global variable
31) Define subroutine prototype
32) Define subroutine then use it
33) Difference between my and local
34) Displays all the arguments
35) Duplicate global and local variable name (use strict;)
36) Factorial with recursive function
37) Is a parameter defined
38) Local variable shadows the gloabl variable
39) Local variable shadows the global variable in a subroutine
40) Local variables in subroutines
41) My ($program, $exitCode) = @_; creates two local variables, $program and $exitCode, from @_
42) My value scope
43) My variable
44) My variable is initialized each time
45) My, local and global variable
46) Nested method
47) Nested subroutine
48) Nested subroutine with local variable
49) Output the subroutine arguments using special variable @_
50) Pass file handle global reference to a subroutine
51) Pass reference to a subroutine to another subroutine
52) Pass two array reference to a subroutine
53) Passing a range of value to a subroutine
54) Passing an array and modifying it,as a reference
55) Passing array to a subroutine
56) Passing Arrays
57) Passing arrays to a function
58) Passing by reference with pointers
59) Passing different number of parameter to a subroutine
60) Passing hash to a subroutine
61) Passing parameters to subroutines
62) Passing References to a Subroutine
63) Passing two values to a subroutine
64) Prototypes
65) Recursive factorial subroutine
66) Recursive fibonacci function
67) Recursive subroutine
68) References to subroutines
69) Return a reference from a sub
70) Return a subroutine from a subroutine
71) Return hash value from subroutine
72) Return more than one value from subroutine
73) Return reference from a function
74) Return reference to variable
75) Return two array references from a subroutine
76) Return two arrays from subroutine
77) Return Value
78) Return value based on context
79) Return value from subroutine reference
80) Return value from subroutine without using the return statement
81) Returning arrays from subroutines
82) Returning data from subroutines
83) Scalar and list Context
84) Shift parameter
85) Subroutine parameter default value
86) Subroutine with arguments defined before it is used
87) Subroutine with no arguments defined after it is used
88) Subroutine with no arguments defined before it is used
89) Swap array value by using the sub range
90) The last statement is the value to return
91) The loop displays each individual argument
92) The return values of the ref function
93) The scope of my variables
94) The wantarray Function and User-Defined Subroutines
95) Use my to declare local variable
96) Using - operator to call a subroutine by its reference
97) Using closures
98) Using local
99) Using my
100) Using my if statement
101) Using my to declare the local variable in a subroutine
102) Using return statement
103) Using shift(@_) to get value passed into a subroutine
104) Using the return statement
105) Wantarray function
106) Wantarray() returns true if caller wants list, false if caller wants scalar, and an undefined value if the caller wants nothing
107) Write recursive subroutines